import { defineConfig } from "vitest/config";
import vue from "@vitejs/plugin-vue";
import { playwright } from "@vitest/browser-playwright";
export default defineConfig({
  test: {
    projects: [
      // 为 packages 目录下的测试项目配置测试环境
      {
        plugins: [vue()],
        test: {
          globals: true,
          name: "packages",
          include: ["packages/**/__test__/**/*.{test,spec}.{ts,js,tsx,jsx}"],
          browser: {
            enabled: true,
            provider: playwright(),
            instances: [{ browser: "chromium" }]
          }
        }
      }
    ]
  }
});
